package com.kgc.exception;

import lombok.Getter;
import lombok.Setter;

/**
 * @Author: luo
 * @date: 2024/4/7 10:05
 * @Description:
 * @Version: 1.0
 *
 * 业务异常
 */

@Setter
@Getter
public class BusinessException extends RuntimeException{

    private Integer code;//错误编码


    public BusinessException(String message, Integer code) {
        super(message);
        this.code = code;
    }

    public BusinessException(String message, Throwable cause, Integer code) {
        super(message, cause);
        this.code = code;
    }
}
